package fr.sharpe.app.earthvisualizationdatamodel;

import gov.nasa.worldwind.geom.Position;
import gov.nasa.worldwind.layers.MarkerLayer;
import gov.nasa.worldwind.render.Material;
import gov.nasa.worldwind.render.markers.BasicMarker;
import gov.nasa.worldwind.render.markers.BasicMarkerAttributes;
import gov.nasa.worldwind.render.markers.Marker;

import java.awt.Color;
import java.io.Serializable;

public class MarkerPoint implements Serializable {
	
	private String id;
	private double latitude;
	private double longitude;
	private double altitude;
	private Color material;
	private String shapeType;
	private double opacity;
	private double markerPixels;
	private double minMarkerSize;
	private double maxMarkerSize;
	private Data data;
	
	public MarkerPoint(String id,double latitude, double longitude, double altitude, Color color,
			String shapeType, double opacity, double markerPixels, double minMarkerSize, double maxMarkerSize, Data data)
	{
		this.id = id;
		this.latitude = latitude;
		this.longitude = longitude;
		this.altitude = altitude;
		this.shapeType = shapeType;
		this.opacity = opacity;
		this.markerPixels = markerPixels;
		this.minMarkerSize = minMarkerSize;
		this.maxMarkerSize = maxMarkerSize;
		this.material = color;
		this.data = data;
		
	}
	
	public Marker getPoint()
	{
		BasicMarkerAttributes attributes = new BasicMarkerAttributes(Material.RED, "SPHERE", 0.5d, 2, 2);
		return new BasicMarker(Position.fromDegrees(this.latitude, this.longitude, altitude),attributes);
	}
	
	public String getId()
	{
		return this.id;
	}

	public double getLatitude() {
		return latitude;
	}

	public void setLatitude(double latitude) {
		this.latitude = latitude;
	}

	public double getLongitude() {
		return longitude;
	}

	public void setLongitude(double longitude) {
		this.longitude = longitude;
	}

	public double getAltitude() {
		return altitude;
	}

	public void setAltitude(double altitude) {
		this.altitude = altitude;
	}

	public Color getMaterial() {
		return material;
	}

	public void setMaterial(Color material) {
		this.material = material;
	}

	public String getShapeType() {
		return shapeType;
	}

	public void setShapeType(String shapeType) {
		this.shapeType = shapeType;
	}

	public double getOpacity() {
		return opacity;
	}

	public void setOpacity(double opacity) {
		this.opacity = opacity;
	}

	public double getMarkerPixels() {
		return markerPixels;
	}

	public void setMarkerPixels(double markerPixels) {
		this.markerPixels = markerPixels;
	}

	public double getMinMarkerSize() {
		return minMarkerSize;
	}

	public void setMinMarkerSize(double minMarkerSize) {
		this.minMarkerSize = minMarkerSize;
	}

	public double getMaxMarkerSize() {
		return maxMarkerSize;
	}

	public void setMaxMarkerSize(double maxMarkerSize) {
		this.maxMarkerSize = maxMarkerSize;
	}

	public Data getData() {
		return data;
	}

	public void setData(Data data) {
		this.data = data;
	}

	public void setId(String id) {
		this.id = id;
	}

}
